/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package Proxy3;

/**
 *
 * @author lcc
 */
public class ImageProxy implements Image{

    public String fileName;
    public String extent;
    public RealImage image;

    public ImageProxy(String fileName) {
        this.fileName = fileName;
    }
    
    
    
    @Override
    public void draw() {
        if (image == null) {
            image = new RealImage(fileName);
        }
        image.draw();
    }

    @Override
    public void getExtent() {
        throw new UnsupportedOperationException("Not supported yet.");
    }

    @Override
    public void store() {
        throw new UnsupportedOperationException("Not supported yet.");
    }

    @Override
    public void load() {
        throw new UnsupportedOperationException("Not supported yet.");
    }
    
}
